#include "widget.h"
#include "ui_widget.h"
#include <QPushButton>
#include <QLayout>

Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);

    QPushButton* pushbutton1 = new QPushButton("按钮1");
    QPushButton* pushbutton2 = new QPushButton("按钮2");
    QPushButton* pushbutton3 = new QPushButton("按钮3");
    QVBoxLayout* layout = new QVBoxLayout(this);
    layout->addWidget(pushbutton1);
    layout->addWidget(pushbutton2);
    layout->addWidget(pushbutton3);
}

Widget::~Widget()
{
    delete ui;
}

